package com.probox.common.entity.service.customer;

import com.baomidou.mybatisplus.extension.service.IService;
import com.probox.common.entity.domain.customer.CustomerPrivilege;
import com.probox.customer.api.domain.LevelAndPrivilege;

import java.util.List;

/**
 * 客户权益Service接口
 *
 * @author zsy
 * @date 2021-05-27
 */
public interface ICustomerPrivilegeService extends IService<CustomerPrivilege> {
    /**
     * 查询用户的打折
     *
     * @param customerUid
     * @return
     */
    public CustomerPrivilege getByCustomerUid(Long customerUid);

    public CustomerPrivilege queryOne(CustomerPrivilege customerPrivilege);

    /**
     * 查询客户权益
     *
     * @param customerPrivilegeUid 客户权益ID
     * @return 客户权益
     */
    public CustomerPrivilege selectCustomerPrivilegeById(Long customerPrivilegeUid);


    /**
     * 查询客户权益列表
     *
     * @param customerPrivilege 客户权益
     * @return 客户权益集合
     */
    public List<CustomerPrivilege> queryList(CustomerPrivilege customerPrivilege);


    /**
     * 新增客户权益
     *
     * @param customerPrivilege 客户权益
     * @return 结果
     */
    public boolean insertCustomerPrivilege(CustomerPrivilege customerPrivilege);

    /**
     * 修改客户权益
     *
     * @param customerPrivilege 客户权益
     * @return 结果
     */
    public boolean updateCustomerPrivilege(CustomerPrivilege customerPrivilege);

    /**
     * 批量删除客户权益
     *
     * @param customerPrivilegeUids 需要删除的客户权益ID
     * @return 结果
     */
    public boolean deleteCustomerPrivilegeByIds(Long[] customerPrivilegeUids);

    public List<CustomerPrivilege> getLevelAndPrivilegeRelation();

    List<LevelAndPrivilege> getLevelAndPrivilege(Long levelId);
}
